<?php

/**
 * Created by PhpStorm.
 * User: apple
 * Date: 2018/11/24
 * Time: 11:10 AM
 */
class ShopValidate extends \think\Validate
{
    public function getError()
    {
        return json([
            'code' => 1002,
            'message' => parent::getError(),
            'data' => [],
        ]);
    }

    public function scene($name, $fields = null)
    {
        if ($name === '') return $this;

        return parent::scene($name, $fields);
    }

}